package vargapeter.bet.client;

import java.io.IOException;
import java.util.ArrayList;
import java.util.List;

import vargapeter.bet.Log;

public class Main {
	
	/**
	 * elindítja a fogadóiroda szervereket (rmi service-ek)
	 * @param args
	 */
	public static void main(String[] args) {
		try {
			Log.init();
			List<Integer> ports = getPorts();
			SportEventManager sportEventManager = new SportEventManager(ports);
			sportEventManager.init();
			SportBetterManager sportBetterManager = new SportBetterManager(ports);
			sportBetterManager.init();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}

	/**
	 * Visszaadja az RMI portokat.
	 * @return
	 */
	private static List<Integer> getPorts() {
		List<Integer> ports = new ArrayList<Integer>();
		ports.add(6661);
		ports.add(6662);
		return ports;
	}
}
